package com.uqbar.game.components.extra;

import java.awt.Color;
import java.awt.Font;

import com.uqbar.game.scene.PlayScene;
import com.uqbar.vainilla.DeltaState;
import com.uqbar.vainilla.GameComponent;
import com.uqbar.vainilla.GameScene;
import com.uqbar.vainilla.appearances.Label;

public class Score extends GameComponent<GameScene> {
	
	private PlayScene playScene;
	
	public Score(PlayScene playScene, int x, int y){
		super(x, y);
		this.playScene = playScene;
	}
	
	public void update(DeltaState deltaState) {
		super.update(deltaState);
		
		Font fuente = new Font("Arial", Font.BOLD, 25);
		Label labelPuntaje = new Label( fuente, Color.white, ""+this.playScene.getSpacecraft().getScore());
		
		this.setAppearance(labelPuntaje);
	}
}
